package org.apache.solr.ocean.replication;

import org.apache.solr.common.params.ModifiableSolrParams;
import org.apache.solr.common.params.SolrParams;
import org.apache.solr.handler.RequestHandlerBase;
import org.apache.solr.handler.RequestHandlerUtils;
import org.apache.solr.ocean.OceanCore;
import org.apache.solr.ocean.OceanSearcher;
import org.apache.solr.request.SolrQueryRequest;
import org.apache.solr.request.SolrQueryResponse;

/**
 * Returns transaction
 *
 */
public class ReplicationRequestHandler extends RequestHandlerBase {
  public void handleRequestBody(SolrQueryRequest request, SolrQueryResponse response) throws Exception {
    RequestHandlerUtils.addExperimentalFormatWarning(response);
    SolrParams params = request.getParams();
    ModifiableSolrParams newParams = new ModifiableSolrParams(params);
    newParams.set("wt", "oceantransaction");
    request.setParams(newParams);
    OceanSearcher oceanSearcher = (OceanSearcher)request.getSearcher();
    OceanCore oceanCore = oceanSearcher.getCore();
    //oceanCore.
  }
  
  public String getDescription() {
    return "";
  }
  
  public String getSourceId() {
    return "";
  }
  
  public String getSource() {
    return "";
  }
  
  public String getVersion() {
    return "1.0";
  }
}
